﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="FlagView.aspx.cs" Inherits="FlagView" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div id="ModuleContent">
        <ul class="NavigationButtons">
            <li>
                <asp:LinkButton ID="lbAddNew" CssClass="navigation_button" Text="Add New" runat="server" PostBackUrl="~/FlagEdit.aspx?m=liFlags" />
            </li>
        </ul>
    </div>
    <asp:GridView ID="FlagGirdView" CssClass="skineedgrid" runat="server" DataSourceID="FlagDS" AutoGenerateColumns="false" Width="75%" DataKeyNames="RecordID"
        AllowPaging="true" PageSize="10" AllowSorting="true" >
        <Columns>
            <asp:BoundField DataField="RecordID" HeaderText="RecordID" Visible="False" />
            <asp:BoundField DataField="ID" HeaderText="FlagID" Visible="False" />
            <asp:BoundField DataField="Name" HeaderText="Title" SortExpression="Name" />
            <asp:BoundField DataField="NavigationMode.Name" HeaderText="Regime"  SortExpression="NavigationMode.Name"/>
            <asp:TemplateField>
                <ItemTemplate>
                    <a href="flaghistory.aspx?id=<%#Eval("ID") %>&m=liFlags">History</a>
                </ItemTemplate>
            </asp:TemplateField>
        </Columns>
    </asp:GridView>


    <asp:ObjectDataSource ID="FlagDS" runat="server" SelectMethod="GetFlags" SortParameterName="sortBy" TypeName="DAL.DBManagers.FlagsManager"></asp:ObjectDataSource>
</asp:Content>

